<div id="foodarticle-index">

    <div class="nav">
        <a href="__APP__/FoodArticle/index">全部</a>
        <volist name="foodsectioninfo" id="vo">
            <a href="__APP__/FoodArticle/index/sid/<{$vo.id}>"><{$vo.name}></a>
        </volist>
    </div>

    <notempty name="foodcategoryinfo">
        <div class="cnav">
            <volist name="foodcategoryinfo" id="vo">
                <a href="__APP__/FoodArticle/index/sid/<{$Think.get.sid}>/cid/<{$vo.id}>"><{$vo.name}></a>
            </volist>
        </div>
    </notempty>

        <div class="search">
            <a class="adds" href="__APP__/FoodArticle/add">添加食材</a>
            <if condition="(Think.get.sid eq '') OR (Think.get.cid eq '')">
                <form action="__APP__/FoodArticle/index" method="post" class="select">
                    <else/>
                    <form action="__APP__/FoodArticle/index/sid/<{$Think.get.sid}>/cid/<{$Think.get.cid}>" method="post" class="select">
            </if>
                    关键字 <input type="text" name="key" /> 按
                    <select name="search">
                        <option value="1">ID</option>
                        <option value="2">食材百科名称</option>
                        <option value="3">食材百科别名</option>
                    </select>
                    <empty name="list">
                        <input type="submit" value="搜索" disabled="disabled" />
                        <else />
                        <input type="submit" value="搜索" />
                    </empty>
                </form>

        </div>

        <form action="__APP__/FoodArticle/del" method="post" name="delete" class="delete">
            <table>
                <thead>
                <tr>
                    <th>ID</th>
                    <th>图片</th>
                    <th>食材名称</th>
                    <th>食材别名</th>
                    <th>排序</th>
                    <th>是否发布</th>
                    <th>所属分类</th>
                    <th>所属栏目</th>
                    <th>旺季</th>
                    <th>信息</th>
                    <th class="action" style="width:50px;"><input class="allselect" type="button" value="全选" /></th>
                </tr>
                </thead>
                <tbody>
                <empty name="list">
                    <tr><td colspan="11" style="height:50px;">暂无数据</td></tr>
                    <else/>
                    <volist name="list" id="vo">
                        <tr>
                            <td><{$vo.id}></td>
                            <td style="width:80px;">
                                <a class="img" href="__APP__/FoodArticle/edit/sid/<{$vo.sectionid}>/cid/<{$vo.categoryid}>/id/<{$vo.id}>" title="修改该食材单元信息">
                                    <empty name="vo.image">
                                            <img src="__PUBLIC__/Content/FoodArticle/thumb_default.jpg" />
                                        <else/>
                                            <img src="__PUBLIC__/Content/FoodArticle/thumb_<{$vo.image}>" />
                                    </empty>
                                </a>
                            </td>
                            <td><a href="__APP__/FoodArticle/edit/sid/<{$vo.sectionid}>/cid/<{$vo.categoryid}>/id/<{$vo.id}>" title="修改该食材单元信息"><{$vo.name}></a></td>
                            <td><{$vo.alias}></td>
                            <td><{$vo.sort}></td>
                            <eq name="vo.publish" value="1">
                                <td>已发布</td>
                                <else/>
                                <td>未发布</td>
                            </eq>
                            <td><a href="__APP__/FoodArticle/index/sid/<{$vo.sectionid}>/cid/<{$vo.categoryid}>"><{$vo.foodcategory.name}></a></td>
                            <td><a href="__APP__/FoodCategory/index/sid/<{$vo.sectionid}>"><{$vo.foodsection.name}></a></td>
                            <eq name="vo.onseason" value="1">
                                    <td>YES</td>
                                <else/>
                                    <td></td>
                            </eq>
                            <td style="width:100px;">
                                <a href="__APP__/FoodNutritions/edit/sid/<{$vo.sectionid}>/cid/<{$vo.categoryid}>/aid/<{$vo.id}>/id/<{$vo.foodnutritions.id}>" class="adisplay">营养信息</a>
                            </td>
                            <td><input type="checkbox" name="actions[]" value="<{$vo.id}>" /></td>
                        </tr>
                    </volist>
                </empty>
                </tbody>
                <tfoot>
                    <empty name="show">
                        <tr><td class="fpage" colspan="11">暂无数据</td></tr>
                        <else/>
                        <tr><td class="fpage" colspan="10"><{$show}></td><td><input class="buttondel" type="button" value="删除" /></td></tr>
                    </empty>
                </tfoot>
            </table>

        </form>
</div>
<script type="text/javascript" src="../Public/js/foodarticle.js"></script>